package wrapper;

public class IntegerDemo {
    public static void main(String[] args) {
        Integer i1 = new Integer(5);
        Integer i2 = new Integer(5);
        System.out.println(i1==i2);
        System.out.println(i1.equals(i2));
        Integer i3 = Integer.valueOf(5);
        Integer i4 = Integer.valueOf(5);
        System.out.println(i3==i4);
        System.out.println(i3.equals(i4));

        Integer i = new Integer(5);
        int j = i.intValue();
        System.out.println(j);

        Integer m = 15;
        int n = m;
        System.out.println(n);

        int max = Integer.MAX_VALUE;
        int min = Integer.MIN_VALUE;
        System.out.println("int最大值:"+max+",最小值:"+min);
        double max1 = Double.MAX_VALUE;
        double min1 = Double.MIN_VALUE;
        System.out.println("double最大值:"+max+",最小值:"+min);

        String str = "100";
        int a = Integer.parseInt(str);
        System.out.println(a);
        String str2 = "1234.4321";
        double d = Double.parseDouble(str2);
        System.out.println(d);

    }
}
